<table class="table table-hover table-condensed ot-api-resource">
    <tbody>
    <tr ng-repeat="item in items"
        ng-show="showLinks || item.type != 'link'"
        class="ot-api-resource-item ot-api-resource-{{item.type}}">
        <td
                class="ot-api-resource-item-name"
                ng-click="toggleCollapsed(item)"
                >
            {{item.name}}
        </td>
        <td class="ot-api-resource-item-value" ng-show="item.collapsed">
            <span class="ot-api-resource-item-collapsed" ng-click="toggleCollapsed(item)">...</span>
        </td>
        <td class="ot-api-resource-item-value" ng-show="!item.collapsed">
            <div ng-if="item.type == 'link'">
                <a ng-click="followResource(item.link)">{{item.link}}</a>
            </div>
            <div ng-if="item.type == 'simple'">
                {{item.value}}
            </div>
            <div ng-if="item.type == 'object'">
                <ot-api-resource-object resource="item.value" show-links="showLinks"></ot-api-resource-object>
            </div>
            <div ng-if="item.type == 'array'">
                <ot-api-resource-object resource="child" show-links="showLinks" ng-repeat="child in item.value"></ot-api-resource-object>
            </div>
            <div ng-if="item.type == 'array-simple'">
                <ul>
                    <li ng-repeat="child in item.value">{{child}}</li>
                </ul>

            </div>
        </td>
    </tr>
    </tbody>
</table>